<template>
  <el-icon class="el-icon" @click="toSwitch">
    <component :is="settingConfig.collapse ? 'Expand' : 'fold'"></component>
  </el-icon>
</template>

<script lang="ts" setup>
import { useSettingConfig } from "@/store/modules/setting";
// 控制图标切换
let settingConfig = useSettingConfig();
// 菜单折叠函数
function toSwitch() {
  settingConfig.collapse = !settingConfig.collapse
}
</script>
<style lang="scss" scoped></style>